{% extends 'admin/layout.html' %}

{% block stylesheets %}
    <!--bootstrap picker-->
    <link rel="stylesheet" type="text/css" href="/admin/js/bootstrap-datepicker/css/datepicker.css"/>
    <link rel="stylesheet" type="text/css" href="/admin/js/bootstrap-timepicker/compiled/timepicker.css"/>
    <link rel="stylesheet" type="text/css" href="/admin/js/bootstrap-colorpicker/css/colorpicker.css"/>
    <link rel="stylesheet" type="text/css" href="/admin/js/bootstrap-daterangepicker/daterangepicker-bs3.css"/>
    <link rel="stylesheet" type="text/css" href="/admin/js/bootstrap-datetimepicker/css/datetimepicker.css"/>
{% endblock %}

{% block page_head %}
    <!-- page head start-->
    <div class="page-head">
        <h3 class="m-b-less">
            新增员工
        </h3>
        <!--<span class="sub-title">Welcome to Static Table</span>-->
        <div class="state-information">
            <ol class="breadcrumb m-b-less bg-less">
                <li><a href="#">首页</a></li>
                <li><a href="#">人事管理</a></li>
                <li class="active">新增员工</li>
            </ol>
        </div>
    </div>
    <!-- page head end-->
{% endblock %}

{% block main_content %}
    <div class="wrapper">
        <div class="row">
            <div class="col-lg-12">
                <section class="panel">
                    <header class="panel-heading head-border">
                        新增员工
                    </header>
                    <div class="panel-body">
                            <form class="form-horizontal" role="form" action="#" method="post">
                                <div class="form-group">
{#                                    <label for="name" class="col-lg-2 col-sm-2 control-label">姓名</label>#}
                                    {{ form.name.label(class="col-lg-2 col-sm-2 control-label") }}
                                    <div class="col-lg-3">
{#                                        <input type="text" class="form-control" id="name" name="name" placeholder="">#}
                                        {{ form.name(class="form-control") }}
                                        <p class="help-block">help text here.</p>
                                    </div>
                                </div>

                                <div class="form-group">
                                    {{ form.department_id.label(class="col-lg-2 col-sm-2 control-label") }}
                                    <div class="col-lg-2">
                                        {{ form.department_id(class="form-control") }}
                                    </div>
                                </div>
                                <div class="form-group">
                                    {{ form.gender.label(class="col-lg-2 col-sm-2 control-label") }}
                                    <div class="col-lg-10">
                                        {% for gender in form.gender %}
                                            <label >
                                                {{ gender }}{{ gender.label }}
                                            </label>
                                        {% endfor %}
                                    </div>
                                </div>

<!--                                <div class="form-group">-->
<!--                                    <label for="birthdate" class="col-lg-2 col-sm-2 control-label">生日</label>-->
<!--                                    <div class="col-lg-3">-->
<!--                                        <input type="text" class="form-control" id="birthdate" name="birthdate" placeholder="">-->
<!--                                    </div>-->
<!--                                </div>-->
                                <div class="form-group">
                                    {{ form.birthdate.label(class="col-lg-2 col-sm-2 control-label") }}
                                    <div class="col-md-3 col-xs-3" data-date-viewmode="years" data-date-format="yyyy-mm-dd" data-date="2012-02-12">
{#                                        <input class="form-control form-control-inline input-medium form_datetime"#}
{#                                               size="16" type="text" value="" name="birthdate" id="birthdate"/>#}
                                        {{ form.birthdate(class="form-control form-control-inline input-medium form_datetime") }}
                                    </div>
                                </div>
                                <div class="form-group">
                                    {{ form.idcard.label(class="col-lg-2 col-sm-2 control-label") }}
                                    <div class="col-lg-4">
                                        {{ form.idcard(class="form-control") }}
                                    </div>
                                </div>
                                <div class="form-group">
                                    {{ form.address.label(class="col-lg-2 col-sm-2 control-label") }}
                                    <div class="col-lg-5">
                                        {{ form.address(class="form-control") }}
                                    </div>
                                </div>
                                <div class="form-group">
                                    {{ form.salary.label(class="col-lg-2 col-sm-2 control-label") }}
                                    <div class="col-lg-2">
                                        {{ form.salary(class="form-control") }}
                                    </div>
                                </div>
                                 <div class="form-group">
                                    {{ form.job.label(class="col-lg-2 col-sm-2 control-label") }}
                                    <div class="col-lg-4">
                                        {{ form.job(class="form-control") }}
                                    </div>
                                </div>

                                <div class="form-group">
                                    <div class="col-lg-offset-2 col-lg-10">
                                        <button type="submit" class="btn btn-primary">提交</button>
                                        <input type="reset" class="btn btn-default" value="重置">
                                        <a href="{{ url_for('admin.emp_list') }}" class="btn btn-default">返回列表</a>
                                    </div>
                                </div>
                            </form>
                        </div>
                </section>
            </div>
        </div>
    </div>

{% endblock %}

{% block scritps %}
<!--bootstrap picker-->
<script type="text/javascript" src="/admin/js/bootstrap-datepicker/js/bootstrap-datepicker.js"></script>
<script type="text/javascript" src="/admin/js/bootstrap-datetimepicker/js/bootstrap-datetimepicker.js"></script>
<script type="text/javascript" src="/admin/js/bootstrap-daterangepicker/moment.min.js"></script>
<script type="text/javascript" src="/admin/js/bootstrap-daterangepicker/daterangepicker.js"></script>
<script type="text/javascript" src="/admin/js/bootstrap-colorpicker/js/bootstrap-colorpicker.js"></script>
<script type="text/javascript" src="/admin/js/bootstrap-timepicker/js/bootstrap-timepicker.js"></script>

<!--picker initialization-->
<script src="/admin/js/picker-init.js"></script>
{% endblock %}